/**
 * 积分管理
 */
import http from "@/utils/http";

/**
 * @description: 积分排名列表
 * @param {*} data
 */
export const getRankList = (data) => {
  return http({
    url: "/backend/PointLog/getUserRankApi",
    method: "POST",
    data,
  });
};

/**
 * @description: 积分流水统计
 * @param {*} data
 */
export const getScoreStatistics = (data) => {
  return http({
    url: "/backend/PointLog/getDataStatisticsApi",
    method: "POST",
    data,
  });
};

/**
 * @description: 积分流水列表
 * @param {*} data
 */
export const getMoneyList = (data) => {
  return http({
    url: "/backend/PointLog/getListApi",
    method: "POST",
    data,
  });
};

/**
 * @description: 积分配置保存
 * @param {*} data
 */
export const SaveScoreConfig = (data) => {
  return http({
    url: "/backend/PointConfig/getSaveApi",
    method: "POST",
    data,
  });
};

/**
 * @description: 获取积分配置
 * @param {*} data
 */
export const getScoreConfig = (data) => {
  return http({
    url: "/backend/PointConfig/getDetailsApi",
    method: "POST",
    data,
  });
};

/**
 * @description: 获取积分模块类型
 * @param {*} data
 */
export const getScoreModuleType = (data) => {
  return http({
    url: "/backend/PointLog/getModuleTypeDataApi",
    method: "POST",
    data,
  });
};

/**
 * @description: 获取积分类型
 * @param {*} data
 */
export const getScoreType = (data) => {
  return http({
    url: "/backend/PointLog/getTypeApi",
    method: "POST",
    data,
  });
};

/**
 * @description: 获取用户积分列表
 * @param {*} data
 */
export const getUserDetailsScore = (data) => {
  return http({
    url: "/backend/PointLog/getUserDetailsApi",
    method: "POST",
    data,
  });
};

/**
 * @description: 居民积分管理
 * @param {*} data
 */
export const getUserScoreManage = (data) => {
  return http({
    url: "/backend/User/getListUser",
    method: "POST",
    data,
  });
};

/**
 * @description: 居民积分管理--赋分
 * @param {*} data
 */
export const addUserPoint = (data) => {
  return http({
    url: "/backend/User/addUserPoint",
    method: "POST",
    data,
  });
};

/**
 * @description: 居民积分管理--积分二维码
 * @param {*} data
 */
export const UserQrcode = (data) => {
  return http({
    url: "/backend/User/getUidQrcode",
    method: "POST",
    data,
  });
};

/**
 * @description: 积分流水导出列表
 * @param {*} data
 */
export const exportPointExcel = (data) => {
  return http({
    url: "backend/PointLog/getListExport",
    method: "POST",
    data,
  });
};

/**
 * @description: 居民积分管理导出列表
 * @param {*} data
 */
export const exportUserExcel = (data) => {
  return http({
    url: "/backend/User/getListExport",
    method: "POST",
    data,
  });
};
